#include<stdio.h>
int main()
{
    int a,b,c=0;
    scanf("%d:%d:%d",&a,&b,&c);
    int d=a*3600+b*60+c+1;
    int e=d/3600;
    int f=(d%3600)/60;
    int g=d%60;
    if(e>=24)e-=24;
    printf("%02d:%02d:%02d",e,f,g);
    /*if(e>10)printf("%d:",e);
    else printf("0%d:",e);
    if(f>10)printf("%d:",f);
    else printf("0%d:",f);
    if(g>10)printf("%d:",g);
    else printf("0%d",g);*/
    return 0;
}
